﻿<phone:PhoneApplicationPage 
    x:Class="OcrSampleApp.MainPage"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:localControls="clr-namespace:OcrSampleApp.Controls"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:controls="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone.Controls"
    xmlns:phone="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone"
    xmlns:shell="clr-namespace:Microsoft.Phone.Shell;assembly=Microsoft.Phone"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d" d:DesignWidth="480" d:DesignHeight="768"
    FontFamily="{StaticResource PhoneFontFamilyNormal}"
    FontSize="{StaticResource PhoneFontSizeNormal}"
    Foreground="{StaticResource PhoneForegroundBrush}"
    SupportedOrientations="Portrait" Orientation="Portrait"
    shell:SystemTray.IsVisible="True">

    <Grid x:Name="LayoutRoot" Background="{StaticResource PhoneChromeBrush}">
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto"/>
            <RowDefinition Height="*"/>
        </Grid.RowDefinitions>

        <!--TitlePanel contains the name of the application and page title-->
        <StackPanel x:Name="TitlePanel" Grid.Row="0" Margin="12,17,0,0">
            <TextBlock x:Name="ApplicationTitle" Text="Contact Picker" Style="{StaticResource PhoneTextNormalStyle}" Margin="0"/>
        </StackPanel>

        <Grid 
            x:Name="HawaiiAppIdErrorArea"
            Grid.Row="1" 
            Margin="12,40,12,20" 
            Visibility="Collapsed">
            <TextBlock TextWrapping="Wrap">
                <Run>The Azure data market client Id or secret is missing.</Run><LineBreak/><LineBreak/>
                <Run>In order to run this sample you need to</Run><LineBreak/>
                <Run>obtain Adm client Id and sign up Hawaii service from</Run><LineBreak/>
                <Run>http://datamarket.azure.com</Run><LineBreak/>
                <Run>Use that Id in the source file HawaiiClient.cs</Run>
            </TextBlock>
        </Grid>

        <Grid x:Name="ContentPanel" Grid.Row="1" Margin="12,0,12,0">
            <controls:Pivot x:Name="mainPivot">
                <controls:PivotItem Margin="0" Header="Select">
                    <localControls:PhotoSelector x:Name="photoSelector"/>
                </controls:PivotItem>
            </controls:Pivot>
        </Grid>
    </Grid>

    <phone:PhoneApplicationPage.ApplicationBar>
        <shell:ApplicationBar IsVisible="false" IsMenuEnabled="False" >
            <shell:ApplicationBarIconButton x:Name="appBarSimpleMode" IconUri="/Images/OcrSimpleMode.png" Text="simple" Click="ApBarSimpleMode_Click" />
            <shell:ApplicationBarIconButton x:Name="appBarDetailedMode" IconUri="/Images/OcrDetailsMode.png" Text="detailed" Click="AppBarDetailedMode_Click" />
        </shell:ApplicationBar>
    </phone:PhoneApplicationPage.ApplicationBar>

</phone:PhoneApplicationPage>